This set of scripts, HTML documents, and GIFs provide an example of multiple ways to deal with serving clickable maps. There are a few major techniques that can be used. They are:

  1. using AppleScript or applications to generate HTML on the fly and interpret clicks.
  2. using a combination of HTML files and AppleScripts to present info and interpret clicks.
  3. using URL redirection to tell clients to go look elsewhere for HTML data based on a mouse click.
  4. reading HTML from a file and returning it from a script or application in response to a mouse click.

The first three items are demonstrated in the following set of examples. Click here to begin the demo.

Important Note!

There are MAJOR differences in how AppleScript scripts behave versus AppleScript or stand-alone applications with regards to working directories. If you run a script (MacHTTP type SCRIPT), it runs as if the current working directory is the same as MacHTTP's. If you run an application to handle a search or a map, then it runs with the working directory set to where it was launched from.

The scripts that are part of this demo were developed as SCRIPT type AppleScripts. If you change any of them to be APPL types (compiled applications or scripts), you will need to change the URL paths accordingly (i.e., remove the "map demo/" portion of the paths.)